package com.lw.system;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;

import com.lw.util.excel.ExcelAttribute;
import lombok.Getter;
import lombok.Setter;
import org.apache.ibatis.annotations.Many;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

@TableName(value = "role")
@Getter
@Setter
public class Role implements Serializable {
    private static final long serialVersionUID = 594829320797158219L;
    @ExcelAttribute( sort = 0)
    private String id;
    /**
     * 角色名
     */
    @ExcelAttribute( sort = 1)
    private String name;
    /**
     * 说明
     */
    @ExcelAttribute( sort = 2)
    private String description;
    /**
     * 企业id
     */
    private String companyId;


//    private Set<User> users = new HashSet<User>(0);//角色与用户   多对多
//
//
//

    @TableField(exist = false)
    private List<Permission> permissions = new ArrayList<>();//角色与模块  多对多
}